package com.lm.controller;

import com.lm.annotation.OperationLog;
import org.springframework.web.bind.annotation.GetMapping;
import org.springframework.web.bind.annotation.RestController;

/**
 * 测试切面Around执行两次情况(未测试成功)
 * @author LM
 * @date 2025/2/8 17:01
 */
@RestController
public class OperationLogController {

    @OperationLog
    @GetMapping("/log/sale")
    public void say() {
        System.out.println("测试");
    }

    @GetMapping("/log/sale2")
    public void say02() {
        say02("lm",12);
    }


    @OperationLog
    public void say02(String name, int age) {
        System.out.println(name + " current age is " + age);
    }
}
